# -*- coding: utf-8 -*-

from PyQt4 import QtGui

from ui.uiSearchDb import UiSearchDb
from db.dataBase import DataBase
from actions.actionsUiSearchDb import ActionsUiSearchDb


class RunnerUiSearchDb(QtGui.QDialog):

    def __init__(self, parent = None):
        """
            Construtor da classe.
        """
        QtGui.QDialog.__init__(self, parent)
        self.setupUi()



    def setupUi(self):
        """
            Instancia e inicia os modulos necessarios.
        """
        self.uiSearchDb = UiSearchDb()
        self.uiSearchDb.setupUi(self)
        self.db = DataBase()
        self.actionsUiDbSearch = ActionsUiSearchDb(self.uiSearchDb, self.db)



    def run(self):
        """
            Metodo para rodar a aplicacao.
        """
        self.uiSearchDb.dialog.show()

